package indi.zhifa.recipe.bailan.framework.auth.util;

import indi.zhifa.recipe.bailan.framework.auth.entity.vo.PasswdEncryptKeyVo;

public interface IZfEncryptUtil {

    /*aes*/
    String AES_HTTP_SESSION_KEY = "ASC_KEY";
    int AES_KEY_LEN = 256;
    String aesKey();
    String aesEncode(String pContent);
    String aesDecode(String pCiphertext);


    /*des*/
    String DES_HTTP_SESSION_KEY = "DES_KEY";
    int DES_KEY_LEN = 192;
    String desKey();
    String desEncode(String pContent);
    String desDecode(String pCiphertext);

    /*RSA*/
    String RSA_HTTP_SESSION_KEY = "RSA_KEY";
    int RSA_KEY_LEN = 768;
    String rsaKey();
    String rsaEncode(String pContent);
    String rsaDecode(String pCiphertext);

    /*SM2*/
    String SM2_HTTP_SESSION_KEY = "SM2_KEY";
    String sm2Key();
    String sm2Encode(String pContent);
    String sm2Decode(String pCiphertext);

    /*SM3*/
    String sm3Digest(String pContent);
    /*MD5*/
    String md5Digest(String pContent);

    /*userName*/
    String USER_ENCRYPT_HTTP_SESSION_KEY = "USER_ENCRYPT_KEY";
    String userNameKey();
    String userNameEncode(String pUserName);
    String userNameDecode(String pCiphertext);
    /*passwd*/
    String PASSWD_ENCRYPT_HTTP_SESSION_KEY = "PASSWD_ENCRYPT_KEY";
    int PASSWD_SALT_LEN = 8;
    PasswdEncryptKeyVo passwdKey();
    String passwdEncode(String pPasswd);
    String passwdDecode(String pCiphertext);
}
